import Vue from 'vue'
import Router from 'vue-router'
import ElementUI from 'element-ui';
import 'element-ui/lib/theme-chalk/index.css';
import 'element-ui/lib/index.js';
// import Pay from "./components/Pay";




Vue.use(Router)

export default new Router({
  mode: 'history',
  base: process.env.BASE_URL,
  routes: [
	/* {
		    path: '/guanggao',
		    name: 'guanggao',
		    component: () => import('./views/guanggao1.vue'),
		  }, */
	  {
		  path:'/',
		  redirect: '/home'
	  },
    {
      path: '/home',
      name: 'home',
      component: () => import('./views/Home.vue'),
    },
    {
      path: '/detail/:id',
      name: 'detail',
      component: () => import('./views/detail/index.vue')
    },
    {
      path: '/book/:id/:chapterno',
      name: 'book',
      component: () => import('./views/Chapter.vue')
    },
    {
      path: '/search',
      name: 'search',
      component: () => import('./views/SearchResult.vue'),
    },
	{
	  path: '/login',
	  name: 'login',
	  component: () => import('./views/Login.vue'),
	},
	{
	  path: '/signin',
	  name: 'signin',
	  component: () => import('./views/Signin.vue'),
	},
	{
	  path: '/content',
	  name: 'content',
	  component: () => import('./components/BookContent.vue'),
	},
	 {
	    path: '/pay',
	    name: 'pay',
		component: () => import('./views/Pay.vue'),
	 },
	{
	  path: '/rank',
	  name: 'rank',
	  component: () => import('./components/NovelRanking.vue'),
	},

	/* {
	  path: '/bookdetail',
	  name: 'bookdetail',
	  component: () => import('./components/BookDetail.vue'),
	}, */
  ]
})
